<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org" lang="en">
	<head>
		<meta charset="utf-8">
		<title>继续上传题库题目</title>
		<link href="css/app.css" rel="stylesheet">
		<link rel="stylesheet" href=""/>
		<link rel="stylesheet" href="../../static/css/exam/upexamqmid.css"/>
	</head>
	<body>
		<div class="wrapper">
				<nav id="sidebar" class="sidebar js-sidebar">
					<div class="sidebar-content js-simplebar">
						<a class="sidebar-brand">
			      <span class="align-middle">考试系统</span>
			    </a>
			
						<ul class="sidebar-nav">
							<li class="sidebar-header">
										导航栏
									</li>
							
							
									<li class="sidebar-item">
										<a class="sidebar-link" href="teacher.html" th:if="${usertype} eq '0'" >
							  <i class="align-middle" data-feather="user"></i> <span class="align-middle">个人主页</span>
							</a>
							<a class="sidebar-link" href="/personpage3" th:if="${usertype} eq '1'" >
							  <i class="align-middle" data-feather="user"></i> <span class="align-middle">个人主页</span>
							</a>
							<a class="sidebar-link" href="admin.html" th:if="${usertype} eq '2'" >
							  <i class="align-middle" data-feather="user"></i> <span class="align-middle">个人主页</span>
							</a>
									</li>
							
									<li class="sidebar-item">
										<a class="sidebar-link" href="/myexam">
							  <i class="align-middle" data-feather="check-square"></i> <span class="align-middle">考试主页</span>
							</a>
									</li>
							
									<li class="sidebar-item">
										<a class="sidebar-link" href="/class">
							  <i class="align-middle" data-feather="book"></i> <span class="align-middle">课程主页</span>
							</a>
									</li>
							
									<li class="sidebar-item">
										<a class="sidebar-link" href="/questionbankpage">
							  <i class="align-middle" data-feather="map"></i> <span class="align-middle">题库练习</span>
							</a>
									</li>
									<li class="sidebar-item" th:if="${usertype} eq '0'">
												<a class="sidebar-link" href="/AddExaminfo">
									  <i class="align-middle" data-feather="file"></i> <span class="align-middle">上传考试</span>
									</a>
											</li>
						</ul>
					</div>
				</nav>
			
				<div class="main">
					<nav class="navbar navbar-expand navbar-light navbar-bg">
						<a class="sidebar-toggle js-sidebar-toggle">
							<i class="hamburger align-self-center"></i>
						</a>
			
						<div class="navbar-collapse collapse">
							<ul class="navbar-nav navbar-align">
								<li class="nav-item dropdown">
									<a class="nav-icon dropdown-toggle d-inline-block d-sm-none" href="#" data-bs-toggle="dropdown">
										<i class="align-middle" data-feather="settings"></i>
									</a>
			
									<a class="nav-link dropdown-toggle d-none d-sm-inline-block" href="#" data-bs-toggle="dropdown">
										<i class="align-middle me-2" data-feather="feather"></i>
										<span th:if="${usertype} eq '0'">老师</span>
										<span th:if="${usertype} eq '1'">学生</span>
										<span th:if="${usertype} eq '2'">管理员</span>
										<img src="images/someicon/teacher.jpg" class="avatar img-fluid rounded me-1" alt="老师" th:if="${usertype} eq '0'"/> 
										<img src="images/someicon/student.jpg" class="avatar img-fluid rounded me-1" alt="学生" th:if="${usertype} eq '1'"/> 
										<img src="images/someicon/admin.jpg" class="avatar img-fluid rounded me-1" alt="管理员" th:if="${usertype} eq '2'"/> 
										<span class="text-dark" th:text="${usermail}"></span>
									</a>
									<div class="dropdown-menu dropdown-menu-end">
										<a class="dropdown-item" href="teacherinfoupdate" th:if="${usertype} eq '0'"><i class="align-middle me-1" data-feather="user"></i> 修改信息</a>
										<a class="dropdown-item" href="/newstudentInformation" th:if="${usertype} eq '1'"><i class="align-middle me-1" data-feather="user"></i>  修改信息</a>
										<a class="dropdown-item" href="admininfoupdate" th:if="${usertype} eq '2'"><i class="align-middle me-1" data-feather="user"></i>  修改信息</a>
										<div class="dropdown-divider"></div>
										<a class="dropdown-item" href="logout">Log out</a>
									</div>
								</li>
							</ul>
						</div>
					</nav>
		
				
				<!--在这里写我自己的东西-->
			<section class="mainbox">
				<div class="container-fluid p-0">
						<div class="mb-3">
				
						</div>
						<div class="row">
							<div class="col-md-12">
								<div class="bigbox">
									<div class="typechoose">
											<div class="eachtype">
												<form action="/Addingquestion1" enctype='multipart/form-data' method='POST'>
													<button type="submit" style="width: 80px; height: 40px; border-radius: 20%;border: none;background-color: #17A2B8;">
														<input type="hidden" name="qtype" value=0><br/>
														<h4 style="margin-top:-10px;">
															<font color="white">选择题</font>
														</h4>
													</button>
												</form>
											</div>
											<div class="eachtype">
												<form action="/Addingquestion1" enctype='multipart/form-data' method='POST'>
													<button type="submit" style="width: 80px; height: 40px; border-radius: 20%;border: none;background-color: #17A2B8;">
														<input type="hidden" name="qtype" value=1><br/>
														<h4 style="margin-top:-10px;">
															<font color="white">判断题</font>
														</h4>
													</button>
												</form>
											</div>
											<div class="eachtype">
												<form action="/Addingquestion1" enctype='multipart/form-data' method='POST'>
													<button type="submit" style="width: 80px; height: 40px; border-radius: 20%;border: none;background-color: #17A2B8;">
														<input type="hidden" name="qtype" value=2><br/>
														<h4 style="margin-top:-10px;">
															<font color="white">填空题</font>
														</h4>
													</button>
												</form>
											</div>
											<div class="eachtype">
												<form action="/Addingquestion1" enctype='multipart/form-data' method='POST'>
													<button type="submit" style="width: 80px; height: 40px; border-radius: 20%;border: none;background-color: #17A2B8;">
														<input type="hidden" name="qtype" value=3><br/>
														<h4 style="margin-top:-10px;">
															<font color="white">简答题</font>
														</h4>
													</button>
												</form>
											</div>
											<div class="eachtype"></div>
											<div class="eachtype"></div>
											<div class="eachtype">
												
											</div>
											<div class="eachtype"></div>
											<div class="eachtype">
												<form action="/backqbank" enctype='multipart/form-data' method='POST'>
													<button type="submit" style="width: 80px; height: 40px; border-radius: 20%;border: none;background-color: #aa0000;">
														<h4 style="margin-top:10px;">
															<font color="white">结束上传</font>
														</h4>
													</button>  
												</form>	
											</div>
									</div>	
									<div class="forinput">
										<div class="subthing">题目id：</div>
										<div class="subthing">
											<p th:text="${newqinfo.id}" style="font-weight:700;"></p>
										</div>
										<div class="subthing">学科：</div>
										<div class="subthing">
											<p th:text="${newqinfo.subject}" style="font-weight:700;"></p>
											</div>
										<div class="subthing">
										</div>
										<div class="subthing">
										</div>	
									</div>
									<div class="forinput">
										<div class="subthing">分值：</div>
										<div class="subthing">
											<p th:text="${newqinfo.point}" style="font-weight:700;">23</p>
										</div>
										<div class="subthing">难度：</div>
										<div class="subthing">
											<div th:if ="${difficulty} lt '0.5'">
												<p style="font-weight:700;">简单</p>
											</div>
											<div th:if ="${difficulty} eq '0.5'">
												<p style="font-weight:700;">中等</p>
											</div>
											<div th:if ="${difficulty} gt '0.5'">
												<p style="font-weight:700;">困难</p>
											</div>
										</div>
										<div class="subthing"></div>
										<div class="subthing"></div>
									</div>
									<div class="forinput2">
										<div class="subthing">题干：</div>
										<div class="subthing">
											<p th:text="${newqinfo.content}" style="margin-left:20px;margin-top:5px;"></p>
										</div>
										<div class="subthing"></div>
										<div class="subthing"></div>
									</div>
									<div class="forinput3">
										<div class="subtext">题目照片：</div>
										<div class="subpic">
											<div th:if="${#strings.isEmpty(newqinfo.picture)}">
												<p>无辅助题目照片</p>
											</div>
											<div th:if="${not #strings.isEmpty(newqinfo.picture)}">
												<img th:src="@{${newqinfo.picture}}" width="100%">
											</div>
										</div>
									</div>
									<!-- 选择题要额外加选项 -->
									<div th:if ="${qtype} eq '0'">
										<div class="forinput2">
											<div th:if="${newqinfo.answer} eq 'A'" class="subthing">
												<input class="form-check-input" type="radio" checked>	
												<span class="form-check-label">A</span>
											</div>
											<div th:if="${newqinfo.answer} ne 'A'" class="subthing">
												<input class="form-check-input" type="radio" >	
												<span class="form-check-label">A</span>
											</div>
											<div class="subthing">
												<p th:text="${newqinfo.optiona}" style="margin-left:20px;margin-top:5px;"></p>
											</div>
											<div class="subthing"></div>
											<div class="subthing"></div>
										</div>
										<div class="forinput2">
											<div th:if="${newqinfo.answer} eq 'B'" class="subthing">
												<input class="form-check-input" type="radio" checked>	
												<span class="form-check-label">B</span>
											</div>
											<div th:if="${newqinfo.answer} ne 'B'" class="subthing">
												<input class="form-check-input" type="radio" >	
												<span class="form-check-label">B</span>
											</div>
											<div class="subthing">
												<p th:text="${newqinfo.optionb}" style="margin-left:20px;margin-top:5px;"></p>
											</div>
											<div class="subthing"></div>
											<div class="subthing"></div>
										</div>
										<div class="forinput2">
											<div th:if="${newqinfo.answer} eq 'C'" class="subthing">
												<input class="form-check-input" type="radio" checked>	
												<span class="form-check-label">C</span>
											</div>
											<div th:if="${newqinfo.answer} ne 'C'" class="subthing">
												<input class="form-check-input" type="radio" >	
												<span class="form-check-label">C</span>
											</div>
											<div class="subthing">
												<p th:text="${newqinfo.optionc}" style="margin-left:20px;margin-top:5px;"></p>
											</div>
											<div class="subthing"></div>
											<div class="subthing"></div>
										</div>
										<div class="forinput2">
											<div th:if="${newqinfo.answer} eq 'D'" class="subthing">
												<input class="form-check-input" type="radio" checked>	
												<span class="form-check-label">D</span>
											</div>
											<div th:if="${newqinfo.answer} ne 'D'" class="subthing">
												<input class="form-check-input" type="radio" >	
												<span class="form-check-label">D</span>
											</div>
											<div class="subthing">
												<p th:text="${newqinfo.optiond}" style="margin-left:20px;margin-top:5px;"></p>
											</div>
											<div class="subthing"></div>
											<div class="subthing"></div>
										</div>
									</div>
									<!-- 判断题的答案是T or F -->
									<div th:if ="${qtype} eq '1'">
										<div class="forinput5">
											<div class="subthing">题目答案：</div>
											<div class="subthing">
												<div class="subsub">
													<div th:if="${newqinfo.answer} eq 'T'">
														<input class="form-check-input" type="radio" name="type" value=1 checked="true">
													</div>
													<div th:if="${newqinfo.answer} ne 'T'">
														<input class="form-check-input" type="radio" name="type" value=1>
													</div>
													<span class="form-check-label">正确</span>
												</div>
												<div class="subsub">
													<div th:if="${newqinfo.answer} eq 'F'">
														<input class="form-check-input" type="radio" name="type" value=1 checked="true">
													</div>
													<div th:if="${newqinfo.answer} ne 'F'">
														<input class="form-check-input" type="radio" name="type" value=1>
													</div>
													<span class="form-check-label">错误</span>
												</div>
												<div class="subsub"></div>
											</div>
											<div class="subthing"></div>
											<div class="subthing"></div>
											<div class="subthing"></div>
											<div class="subthing"></div>
											<div class="subthing"></div>
										</div> 
									</div>
									<div th:if ="${qtype} ge '2'">
										<div class="forinput2">
											<div class="subthing">答案：</div>
											<div class="subthing">
												<p th:text="${newqinfo.answer}" style="margin-left:20px;margin-top:5px;"></p>
											</div>
											<div class="subthing"></div>
											<div class="subthing"></div>
										</div>
									</div>
									<div th:if ="${qtype} eq '3'">
										<div class="forinput3">
											<div class="subtext">题目照片：</div>
											<div class="subpic">
												<div th:if="${#strings.isEmpty(newqinfo.answerpic)}">
													<p>无题目标准答案照片</p>
												</div>
												<div th:if="${not #strings.isEmpty(newqinfo.answerpic)}">
													<img th:src="@{${newqinfo.answerpic}}" width="100%">
												</div>
											</div>
										</div>
									</div>
				</div>
			</section>
				
				<footer class="footer">
					<div class="container-fluid">
						<div class="row text-muted">
							<div class="col-6 text-start">
								<p class="mb-0">
									<a class="text-muted" href="https://adminkit.io/" target="_blank"><strong>AdminKit</strong></a> &copy;
								</p>
							</div>
							<div class="col-6 text-end">
								<ul class="list-inline">
									<li class="list-inline-item">
										<a class="text-muted" href="https://adminkit.io/" target="_blank">Support</a>
									</li>
									<li class="list-inline-item">
										<a class="text-muted" href="https://adminkit.io/" target="_blank">Help Center</a>
									</li>
									<li class="list-inline-item">
										<a class="text-muted" href="https://adminkit.io/" target="_blank">Privacy</a>
									</li>
									<li class="list-inline-item">
										<a class="text-muted" href="https://adminkit.io/" target="_blank">Terms</a>
									</li>
								</ul>
							</div>
						</div>
					</div>
				</footer>
			</div>
		</div>
		
		<script src="js/app.js"></script>
	</body>
</html>
